package main

import (
	"fmt"
	"time"
)

// 没间隔5秒输出当前时间
func TickerDemo() {
	ticker := time.NewTicker(time.Second * 1)
	go func() {
		for t := range ticker.C {
			fmt.Println("Tick at", t.Format("2006.01.02 15:04:05"))
		}
	}()
}
